<div class="table" id="tier1">
	<h2><a href="soldat://fracs.net:20202">#fractured P.P.S. Tier 1</a></h2>
	<div class="content">
		<?php if (!$server): ?>
			<ul class="row"><li class="srvr_error">Unable to establish connection to the server.</li></ul>
		<?php elseif($server['players'] == 0): ?>
			<ul class="row"><li class="srvr_error">The server is empty at the moment.</li></ul>
		<?php else: ?>
			<ul class="srvr_info"> 
				<li class="srvr_map">Map: <?= $server['map'] ?></li>
				<li class="srvr_num_plr">Players: <?= $server['players'] ?>/12</li>
				<li class="srvr_time">Time Left: <?= $server['timeleft'] ?></li>
			</ul>
			<ul class="heading"> 
				<li class="srvr_id">#</li>
				<li class="srvr_plr">Name</li>
				<li class="srvr_kills">Kills</li>
				<li class="srvr_deaths">Deaths</li>
				<li class="srvr_ping">Ping</li>
			</ul>
    		<?php foreach ($server['player'] as $player): ?>
				<ul class="row">
					<li class="srvr_id"><?= $player['id'] ?></li>
					<li class="srvr_plr <?=($player['team']==2)?'plr_bravo':'plr_alpha'?>">
						<?php if (isset($player['user_id'])): ?>
							<?=anchor('stats/player/'.$player['user_id'], $player['name'])?>
						<?php else: ?>
							<?=$player['name']?>
						<?php endif; ?>
					</li>
					<li class="srvr_kills"><?= $player['kills'] ?></li>
					<li class="srvr_deaths"><?= $player['deaths'] ?></li>
					<li class="srvr_ping"><?= $player['ping'] ?></li>
				</ul>
			<?php endforeach; ?>
		<?php endif; ?>
		<ul class="row">
			<li class="srvr_status">
				<?php if ($stats_status['stats_on']): ?>
					Stats Are <span class="on">Enabled</span>
				<?php else: ?>
					Stats Are <span class="off">Disabled</span>
				<?php endif; ?>
			</li>
		</ul>
	</div>
	<span class="fill"></span>
</div>